﻿@model IEnumerable<JRFinances.ViewModels.VirtualTransactions.VirtualTransactionsHistoryViewModel>

<fieldset>
<legend>Historia wirtualnych transakcji</legend>
<p></p>
@{ Html.RenderPartial("_VirtualTransactionHistorySearch");}
<p></p>
<table>
    <tr>
        <th>
            Spolka
        </th>
        <th>
            Data
        </th>
        <th>
            Ilosc
        </th>
        <th>
            Cena
        </th>
        <th>
            Rodzaj
        </th>
        <th>
        </th>
    </tr>
    @foreach (var item in Model)
    {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item.CompanyName)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Date)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Volume)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Price)
            </td>
            <td>
                @if (item.Buy == true)
                {
                    <p>
                        KUPNO</p>
                }
                else
                {
                    <p>
                        SPRZEDAZ</p>
                }
            </td>
            <td>
                @Html.ActionLink("Usun", "Delete", new { id = item.TransactionId })
            </td>
        </tr>
    }
</table>
</fieldset>


